home *** CD-ROM | disk | FTP | other *** search
/ InterCD 2000 September / september_2000.iso / intercd / root / ^Linux / cdrtools-1.10 / include / fctldefs.h < prev    next >
Encoding:
C/C++ Source or Header  |  1999-05-02  |  1.6 KB  |  64 lines

  1. /* @(#)fctldefs.h    1.4 99/05/02 Copyright 1996 J. Schilling */
  2. /*
  3.  *    Generic header for users of open(), creat() and chmod()
  4.  *
  5.  *    Copyright (c) 1996 J. Schilling
  6.  */
  7. /*
  8.  * This program is free software; you can redistribute it and/or modify
  9.  * it under the terms of the GNU General Public License as published by
  10.  * the Free Software Foundation; either version 2, or (at your option)
  11.  * any later version.
  12.  *
  13.  * This program is distributed in the hope that it will be useful,
  14.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  16.  * GNU General Public License for more details.
  17.  *
  18.  * You should have received a copy of the GNU General Public License
  19.  * along with this program; see the file COPYING.  If not, write to
  20.  * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
  21.  */
  22.  
  23. #ifndef _FCTLDEFS_H
  24. #define    _FCTLDEFS_H
  25.  
  26. #ifndef    _MCONFIG_H
  27. #include <mconfig.h>
  28. #endif
  29.  
  30. #include <sys/types.h>
  31. #include <sys/stat.h>
  32.  
  33. #ifdef    HAVE_FCNTL_H
  34.  
  35. #    include <fcntl.h>
  36.  
  37. #else    /* HAVE_FCNTL_H */
  38.  
  39. #    include <sys/file.h>
  40.  
  41. #endif    /* HAVE_FCNTL_H */
  42.  
  43. /*
  44.  * Do not define more than O_RDONLY / O_WRONLY / O_RDWR / O_BINARY
  45.  * The values may differ.
  46.  *
  47.  * O_BINARY is defined here to allow all applications to compile on a non DOS
  48.  * environment without repeating this definition.
  49.  */
  50. #ifndef    O_RDONLY
  51. #    define    O_RDONLY    0
  52. #endif
  53. #ifndef    O_WRONLY
  54. #    define    O_WRONLY    1
  55. #endif
  56. #ifndef    O_RDWR
  57. #    define    O_RDWR        2
  58. #endif
  59. #ifndef    O_BINARY            /* Only present on DOS or similar */
  60. #    define    O_BINARY    0
  61. #endif
  62.  
  63. #endif    /* _FCTLDEFS_H */
  64.